package com.ruoyi.service.impl;

import java.util.List;

import com.ruoyi.domain.BasisUavTable;
import com.ruoyi.domain.BasisUavTableDt;
import com.ruoyi.dto.BasisLoadingUavCamp;
import com.ruoyi.mapper.BasisUavTableDtMapper;
import com.ruoyi.mapper.BasisUavTableMapper;
import com.ruoyi.service.IBasisUavTableService;
import org.apache.ibatis.annotations.Param;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

/**
 * 目标的参数Service业务层处理
 * 
 * @author wangzebing
 * @date 2025-06-23
 */
@Service
public class BasisUavTableServiceImpl implements IBasisUavTableService
{
    @Autowired
    private BasisUavTableMapper basisUavTableMapper;

    @Autowired
    private BasisUavTableDtMapper basisUavTableDtMapper;

    /**
     * 查询目标的参数
     * 
     * @param id 目标的参数主键
     * @return 目标的参数
     */
    @Override
    public BasisUavTable selectBasisUavTableById(Long id)
    {
        return basisUavTableMapper.selectBasisUavTableById(id);
    }

    /**
     * 查询目标的参数列表
     * 
     * @param basisUavTable 目标的参数
     * @return 目标的参数
     */
    @Override
    public List<BasisUavTable> selectBasisUavTableList(BasisUavTable basisUavTable)
    {
        return basisUavTableMapper.selectBasisUavTableList(basisUavTable);
    }

    /**
     * 新增目标的参数
     * 
     * @param basisUavTable 目标的参数
     * @return 结果
     */
    @Override
    public int insertBasisUavTable(BasisUavTable basisUavTable)
    {
        basisUavTableMapper.insertBasisUavTableDt(basisUavTable);
        return basisUavTableMapper.insertBasisUavTable(basisUavTable);
    }

    /**
     * 修改目标的参数
     * 
     * @param basisUavTable 目标的参数
     * @return 结果
     */
    @Override
    public int updateBasisUavTable(BasisUavTable basisUavTable)
    {

        basisUavTableDtMapper.updateBasisUavTableDt2(basisUavTable);
        return basisUavTableMapper.updateBasisUavTable(basisUavTable);
    }

    /**
     * 批量删除目标的参数
     * 
     * @param ids 需要删除的目标的参数主键
     * @return 结果
     */
    @Override
    public int deleteBasisUavTableByIds(Long[] ids)
    {
        return basisUavTableMapper.deleteBasisUavTableByIds(ids);
    }

    /**
     * 删除目标的参数信息
     * 
     * @param id 目标的参数主键
     * @return 结果
     */
    @Override
    public int deleteBasisUavTableById(Long id)
    {
        return basisUavTableMapper.deleteBasisUavTableById(id);
    }

    @Override
    public List<BasisUavTable> findByLoadingIdAndUavIdfFormUavTable(String loadingId, Integer uavId) {
        return basisUavTableMapper.findByLoadingIdAndUavIdfFormUavTable(loadingId, uavId);
    }

    @Override
    public boolean delByLoadingIdAndUavIdfFormUavTable(String loadingId, Integer uavId) {
        return basisUavTableMapper.delByLoadingIdAndUavIdfFormUavTable(loadingId, uavId);
    }

    @Override
    public List<BasisUavTable> findByLoadingIdAndUavIdfFormUavTableDT(String loadingId, Integer uavId) {
        return basisUavTableMapper.findByLoadingIdAndUavIdfFormUavTableDT(loadingId, uavId);
    }

    @Override
    public List<BasisUavTable> findByLoadingIdfFormUavTable(String loadingId) {
        return basisUavTableMapper.findByLoadingIdfFormUavTable(loadingId);
    }

    @Override
    public List<BasisUavTable> findByLoadingIdfAndBusinessInformationFormUavTable(String loadingId) {
        return basisUavTableMapper.findByLoadingIdfAndBusinessInformationFormUavTable(loadingId);
    }


}
